﻿using System.Collections.Generic;
using eCommerce.db.DALRespository;
using eCommerce.db.DataRespository;

namespace eCommerce.db.BORespository
{
    public class DiscountBo
    {
        public static List<DiscountEntity> Search(string startDate, string endDate, int pageIndex, int pageSize, ref int totalRecords)
        {
            return DiscountDal.Search(startDate, endDate, pageIndex, pageSize, ref totalRecords);
        }

        public static DiscountEntity GetById(int id)
        {
            return DiscountDal.GetById(id);
        }

        public static void Create(DiscountEntity o)
        {
            DiscountDal.Create(o);            
        }

        public static void Update(DiscountEntity o)
        {
            DiscountDal.Update(o);
        }

        public static void Delete(int id)
        {
            DiscountDal.Delete(id);
        }
    }
}
